A video includes a series of pictures (or frames), with each frame consisting of a two-dimensional array of pixels. The pixels are divided into blocks (e.g., an 8×8 array of pixels). The video can be encoded (compressed) to reduce overall bit rate so that the video can be more efficiently transmitted to another device, where it can be decoded (decompressed), reconstructed and displayed.
Current video and image compression techniques include lossy processes like perceptual quantization of block transform coefficients. Lossy encoding of independent blocks within a video frame can lead to abrupt transitions, known as blocking artifacts, at block edges in the decoded and reconstructed image, giving the rendered image a relatively blocky appearance.
To eliminate or reduce the appearance of blocking artifacts, decoding devices perform a deblocking operation. In deblocking, a deblock filter (e.g., a low pass digital filter) is applied across block boundaries in order to smooth the transition between adjacent blocks, thereby improving the perceived quality of the displayed video.
However, selecting the proper strength deblock filter can be problematic. If the selected filter is too weak, then it may not effectively reduce the appearance of blocking artifacts. On the other hand, if the selected filter is too strong, it may result in the removal of too much detail.
Selecting the number of pixels to apply the deblock filter to can also be problematic. At one extreme, if the filter is applied only to the pixels immediately next to the block boundaries, then blocking artifacts may not be effectively reduced or eliminated. At the other extreme, if the filter is applied across all of the pixels in a block, then some pixel values may be unnecessarily modified and details inside the block may be lost.